﻿using FluentNHibernate.Mapping;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using Water.Model;

namespace Water.Data.Repositories.Mappings
{
    public class MeterMap : ClassMap<Meter>
    {
        public MeterMap()
        {
            Table("TZ_FJMYHSB");
          //  LazyLoad();
            Id(x => x.METERID).GeneratedBy.Assigned().Column("METER_ID");
            Map(x => x.CUSTID).Column("CUST_ID");
            Map(x => x.CUSTNAME).Column("CUST_NAME");
            Map(x => x.MEASURE).Column("MEASURE");
            Map(x => x.PIPEID).Column("PIPE_ID");
            Map(x => x.LOCATION).Column("LOCATION");
            Map(x => x.ROADNAME).Column("ROADNAME");
            Map(x => x.DATEI).Column("DATE_I");
            Map(x => x.INLETD).Column("INLET_D");
            Map(x => x.METERD).Column("METER_D");
            Map(x => x.TYPE).Column("TYPE");
            Map(x => x.INLETNUM).Column("INLET_NUM");
            Map(x => x.MAXDURATION).Column("MAX_DURATION");
            Map(x => x.CONTACT).Column("CONTACT");
            Map(x => x.OFFDAY).Column("OFF_DAY");
            Map(x => x.PHONE).Column("PHONE");
            Map(x => x.METERTYPE).Column("METER_TYPE");
            Map(x => x.CALIBRATEDAT).Column("CALIBRATE_DAT");
            Map(x => x.REPLACINGDATE).Column("REPLACING_DATE");
            Map(x => x.USAGEQ).Column("USAGE_Q");
            Map(x => x.DEPTH).Column("DEPTH");
            Map(x => x.PAVEMENT).Column("PAVEMENT");
            Map(x => x.YSLB).Column("YSLB");
            Map(x => x.GPS).Column("GPS");
            Map(x => x.ELEV).Column("ELEV");
            Map(x => x.KH).Column("KH");
            Map(x => x.PROJECT).Column("PROJECT");
            Map(x => x.SOURCE).Column("SOURCE");
            Map(x => x.SBLB).Column("SBLB");
            Map(x => x.GJZ).Column("GJZ");
            Map(x => x.PICTURE).Column("PICTURE");
            Map(x => x.SSQX).Column("SSQX");
            Map(x => x.SSZS).Column("SSZS");
            Map(x => x.TFH).Column("TFH");
            Map(x => x.MEMO).Column("MEMO");
            Map(x => x.EpcNO).Column("EpcNO");
        }
    }
}
